<#include "/common/defaultEngine.html"/>
<@pageTheme mark="${config.optimize()?string('true', 'false')}">
<@header title="用户重置密码" bodyClass="white-bg"/>
<div class="wrapper wrapper-content ibox-content">
<@f.form id="form-user-resetPwd" class="form-horizontal">
	<input name="id"  type="hidden"  value="${user.id}" />
	<div class="form-group">
		<label class="col-sm-3 control-label "><@ctx.i18n text = "登陆账号"/>：</label>
		<div class="col-sm-8">
			<p class="form-control-plaintext">${user.username?default('')}</p>
		</div>
	</div>
	<div class="form-group">
		<label class="col-sm-3 control-label"><@ctx.i18n text = "密码"/>：</label>
		<div class="col-sm-8">
			<div class="input-group">
				<@f.input name="password" placeholder="请输入登录密码" required=true type="password" value="${config.getKey('SYS_USER_INITPASSWORD')}"/>
				<span class="input-group-addon" title="<@ctx.i18n text = "登录密码,鼠标按下显示密码"/>"
					  data-toggle="tooltip"
					  data-placement="top" data-custom-class="tooltip-warning"
					  onmousedown="$('#password').attr('type','text')"
					  onmouseup="$('#password').attr('type','password')"><i class="fa fa-fw fa-key"></i></span>
			</div>
		</div>
	</div>
</@f.form>
</div>
<@footer>
<script type="text/javascript">
	$("#form-user-resetPwd").validate({
		rules:{
			password:{
				required:true,
				minlength: 6,
				maxlength: 15
			},
		},
		focusCleanup: true
	});

	function submitHandler() {
		if (opt.validate.form()) {
			opt.operate.save(baseURL + "sys/user/resetPwd", $('#form-user-resetPwd').serialize());
		}
	}
</script>
</@footer>
</@pageTheme>
